Skip to content

[3.13] gh-121018: Fix more cases of exiting in argparse when exit_on_error=False (GH-121056)#121128

Merged
serhiy-storchaka merged 2 commits intopython:3.13from
serhiy-storchaka:backport-81a654a-3.13
Jun 28, 2024
Merged

[3.13] gh-121018: Fix more cases of exiting in argparse when exit_on_error=False (GH-121056)#121128
serhiy-storchaka merged 2 commits intopython:3.13from
serhiy-storchaka:backport-81a654a-3.13

Conversation

@serhiy-storchaka
Copy link
Member

@serhiy-storchaka serhiy-storchaka commented Jun 28, 2024

  • parse_intermixed_args() now raises ArgumentError instead of calling error() if exit_on_error is false.
  • Internal code now always raises ArgumentError instead of calling error(). It is then caught at the higher level and error() is called if exit_on_error is true. (cherry picked from commit 81a654a)

Loading
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant